public class Sum {
    private int x,y,z;
    public void getData(int a,int b){
        x=a;
        y=b;
    }
    public void calcDisplay(){
        z=x+y;
        System.out.println("Sum:"+z);
    }
}
//getData(20,50);